package cn.iocoder.yudao.module.aiposter.service.poster.bo;

import com.fasterxml.jackson.annotation.JsonInclude;
import lombok.*;

import java.io.Serializable;
import java.util.List;

@Data
@ToString(callSuper = true)
@Builder
@NoArgsConstructor
@AllArgsConstructor
@JsonInclude(JsonInclude.Include.NON_NULL)
public class ImgWidgetBO implements Serializable {

    // 是否可以AI生成与ImgWidgetBO.isSegmentation互斥
    private Boolean isAI = false;

    // 是否可以通过抠图与ImgWidgetBO.isAI互斥
    private Boolean isSegmentation = false;

    // 矢量图片 图片 文字
    private String name;

    // w-svg w-text w-image w-qrcode
    private ImgWidgetTypeEnum type;

    // 8fxs9xhs0
    private String uuid;

    // 955.9999779462814
    private Double width;

    // 955.9999779462814
    private Double height;

    // [#ffffff]
    private List<String> colors;

    // 143.9999656677246
    private Double left;

    // 143.9999656677246
    private Double top;

    // scale(1)
    private String transform;

    // 0
    private Integer radius;

    // 1
    private Integer opacity;

    // -1
    private String parent;

    // TODO 未知
    private Object setting;

    // 记录信息
    private Object record;

    private Double letterSpacing;

    private String imgUrl;

    // 0 dog90 等无法确定类型
    private Object rotate;

    private Object filter;

    //####################svg特有

    // https://xxx.svg
    private String svgUrl;

    //####################图片特有
    // 1
    private String zoom;

    // {a:1,b:0,c:0,d:0,tx:0, ty:0}
    private Object imageTransform;

    // 0
    private Integer naturalDuration;

    private String mask;

    //####################文字特有

    //新年大吉
    private String text;

    // false
    private Boolean editable;

    // 172.9
    private Float fontSize;

    //{"alias": "站酷快乐体", "id": 543,"value": "zcool-kuaile-regular","url": "https://lib.baomitu.com/fonts/zcool-kuaile/zcool-kuaile-regular.woff2"}
    private Object fontClass;

    // 400
    private Integer fontWeight;

    // normal
    private String fontStyle;

    // horizontal-tb
    private String writingMode;

    // none
    private String textDecoration;

    // #e253ff
    private String color;

    // center
    private String textAlign;

    // #ffffff
    private String backgroundColor;

    private Double lineHeight;

    private Object textEffects;
    //####################二维码特有
    private String url;

    // classy
    private String dotType;

    // single
    private String dotColorType;

    // 270
    private String dotRotation;

    // #282837
    private String dotColor;

    // #122010
    private String dotColor2;

    // https://xxx.com
    private String value;

    // ##### 组合类数据
    private Boolean isContainer;
}
